import router from './router'
import store from './store'
store.dispatch('permission/generateRoutes')
router.beforeEach(async(to, from, next) => {
    // await store.dispatch('permission/generateRoutes')
    window.scrollTo(0, 0) 
    next()
  })